SpiruSense

SpiruSense

Intelligent Photobioreactor for Spirulina Cultivation and Monitoring

SpiruSense

SpiruSense

Img. 1: SpiruSense, intelligent photobioreactor.

SpiruSense is an intelligent photobioreactor for the cultivation and monitoring of spirulina.

It was developed as my Fab Academy final project and integrates digital fabrication, sensors, electronics, embedded programming, and the Internet of Things.

Final Presentation Video

presentation.mp4 – Complete demonstration of the fabrication, integration, and operation of SpiruSense.

Final presentation video: presentation.mp4

Final Presentation Slide

presentation.png – Summary slide of the SpiruSense system.

Final presentation slide

Final presentation slide: presentation.png

Cultivating microalgae with digital fabrication, sensors, and the Internet of Things.

Where the Idea Was Born: The First Bubbles of SpiruSense

The idea for SpiruSense emerged from the need to improve the traditional spirulina cultivation methods used in the laboratory, where recycled PET bottles and manual monitoring are commonly used.

Although this method works, it has limitations such as the lack of real-time control, absence of data recording, difficulty controlling lighting, limited automation, and dependence on constant supervision.

Initially, I considered developing a submerged liquid fermentation bioreactor for Trichoderma or an intelligent culture collection system for microalgae. However, after analyzing the possibilities of integrating the skills learned during Fab Academy, I decided to evolve the idea into an intelligent photobioreactor.

This is how SpiruSense was born: a system that integrates digital fabrication, electronics, sensors, programming, and IoT to monitor and control the cultivation of Limnospira platensis, commonly known as spirulina.

AI prototype

Img. 2: Prototype created with AI - ChatGPT.

AI prototype

Img. 3: Prototype created with AI - ChatGPT.

What is SpiruSense?

SpiruSense is an intelligent photobioreactor designed for the cultivation and monitoring of spirulina. Its main objective is to improve the monitoring of culture conditions through sensors, local visualization, and remote monitoring.

The system measures important variables such as temperature, pH, total dissolved solids, and light intensity. In addition, it allows remote control of the lighting and aeration of the culture through a platform connected to Firebase.

Current spirulina cultivation

Img. 4: Current spirulina cultivation method.

Main Components

Main Components

Photo Component Description Use in the Project
XIAO ESP32-C3 XIAO ESP32-C3 Microcontroller with integrated WiFi and Bluetooth connectivity. Main unit responsible for reading sensors, processing data, and communicating with Firebase.
DS18B20 DS18B20 Sensor Waterproof digital temperature sensor. Monitoring the temperature of the spirulina culture.
TDS Sensor Gravity TDS Sensor Sensor for measuring total dissolved solids. Estimation of salts and nutrients concentration in the culture medium.
pH Sensor pH E201-C BNC Electrode Analog electrode for pH measurement. Control of the acidity or alkalinity level of the culture.
BH1750 BH1750 Sensor Digital light intensity sensor based on I2C. Measurement of light available for spirulina growth.
LCD 16x2 I2C LCD Screen Alphanumeric display for local visualization. Displays temperature, pH, TDS and light intensity in real time.
Air Pump Air Pump Continuous aeration system. Maintains culture circulation and oxygen transfer.
Relay Module 2-Channel Relay Module Electronic switching module. Controls lighting and aeration remotely.
LED Strip White LED Strip Artificial lighting source. Provides light for photosynthesis.
Power Supply 12V Power Supply DC power source. Main power supply for the entire system.
LM2596 LM2596 Step-Down Adjustable DC-DC converter. Voltage regulation for electronic components.
Logic Converter 5V–3.3V Logic Converter Bidirectional logic level adapter. Ensures safe communication between devices.
Switch ON/OFF Switch Main power switch. Turns the complete system on and off.
PCB Custom PCB Custom electronic board designed and fabricated during Fab Academy. Integrates sensors, actuators and the microcontroller.

Design Options and Evolution

During the development of the project, different design options were evaluated. The first idea was to build a bioreactor for Trichoderma, but this required sterility conditions, mechanical agitation, and more complex microbiological validation.

Later, I considered an intelligent microalgae culture collection system, but this option had less system integration and did not allow me to fully demonstrate the skills developed during Fab Academy.

Finally, I chose to develop an intelligent photobioreactor because it allowed me to integrate 2D and 3D design, additive fabrication, subtractive fabrication, custom electronics, sensors, embedded programming, WiFi communication, IoT, and system integration.

Initial bioreactor idea

Img. 19: Initial bioreactor idea with paddles.

Why It Is Important: Key Benefits

  • ✔️ Real-time monitoring: displays temperature, pH, TDS, and light intensity.
  • ✔️ Remote control: allows lighting and aeration to be turned on and off from Firebase.
  • ✔️ Digital fabrication: much of the system was designed and fabricated using 3D printing, laser cutting, CNC, and thermoforming.
  • ✔️ Low cost: uses accessible sensors and components.
  • ✔️ Educational application: can be used in Fab Labs, institutes, and laboratories to teach biotechnology, electronics, and IoT.
  • ✔️ Scaling potential: can evolve into higher-capacity versions or modular systems.
Real-time monitoring

Img. 20: Real-time monitoring.

Component Cost Summary

The following table summarizes the main components used in SpiruSense, including their quantity and use within the system.

Component Quantity Total Cost (S/.) Total Cost (USD) Use in the Project
XIAO ESP32-C3140.0011.11Main microcontroller.
DS18B20 Sensor15.501.53Temperature measurement.
TDS Sensor175.0020.83Dissolved solids measurement.
pH E201-C BNC Sensor165.0018.06pH measurement.
BH1750 Sensor110.002.78Light intensity measurement.
I2C LCD Screen125.006.94Local visualization.
Air Pump236.0010.00Culture aeration.
Relay Module220.005.56Lighting and aeration control.
LED Strip15.001.39Culture lighting.
12V Power Supply160.0016.67Main power supply.
LM2596 Step-Down Regulator15.001.39Voltage conversion.
5V–3.3V Logic Converter16.001.67Signal adaptation for pH sensor.
ON/OFF Switch15.001.39General power on/off.
Transparent Acrylic160.0016.67Thermoformed cylinder.
PLA Filament175.0020.833D printing of the structure.
PCB and Electronic Components150.0013.89Custom electronic board.
Resistors and ConnectorsSeveral10.002.78Circuitry and connections.
Miscellaneous MaterialsSeveral30.008.33Cables, hoses, screws, and sealing.
Estimated TotalS/ 582.50USD 161.81

The estimated total cost of the prototype was approximately S/ 582.50, equivalent to USD 161.81, not including the use of Fab Lab machines or the hours of design, fabrication, and programming.

Intermediate Review – SpiruSense Project

From concept to final integration, SpiruSense was developed through several stages of design, fabrication, testing, and redesign.

1. Confirmed Functionalities

Functionality Description Validation
Temperature monitoringDS18B20 sensor reading.Reading tests on LCD and Firebase.
pH monitoringE201-C BNC electrode reading.Calibration tests with buffer solutions.
TDS monitoringDissolved solids reading.Tests in liquid medium.
Light measurementBH1750 sensor reading.Light intensity tests.
LCD screenLocal visualization of parameters.Real-time data displayed.
WiFi communicationESP32-C3 internet connection.Data sent to Firebase.
Lighting controlRemote LED activation.On/off control from the platform.
Aeration controlRemote pump activation.Remote control through Firebase.

2. General Project Workflow Description

Design and Prototyping

  • ✔️ Initial system sketches.
  • ✔️ CAD design in Fusion 360.
  • ✔️ Design of base, lid, central column, aerator, and supports.

The project began with the question: how can spirulina cultivation be improved using digital fabrication and IoT?

Based on this question, initial sketches were made and the general structure of the photobioreactor was designed. The design had to contain the culture, integrate sensors, house the electronics, allow the passage of hoses and cables, and maintain an appearance close to a finished product.

The structure was modeled in Fusion 360, considering:

  • Cylinder diameter: 20 cm.
  • Culture height: 35 cm.
  • LCD screen location.
  • Compartment for the pump.
  • Space for the electronics.
  • Internal supports.
  • Sensor and hose entry.
Initial Fusion 360 design

Img. 21: Initial design in Fusion 360.

Base design

Img. 22: Design of the base that contains the electrical system.

Final photobioreactor design

Img. 23: Final photobioreactor design.

Digital Fabrication

  • ✔️ 3D printing of the base, lid, and aeration system.
  • ✔️ Laser cutting of mold parts.
  • ✔️ CNC for mold components.
  • ✔️ Thermoforming of the acrylic cylinder.

The base, lid, central column, and aeration system were fabricated by 3D printing using PLA.

The transparent cylinder was fabricated by thermoforming acrylic. For this, a mold made with laser cutting and CNC was used. This process required several attempts until a functional shape was obtained, because the first tests showed deformations.

The result was a transparent acrylic cylinder that allows the culture to be observed and houses the internal lighting system.

3D printing parameters

Img. 24: Adjustment of PLA printing parameters.

3D printed parts

Img. 25: 3D printed parts.

Thermoforming mold

Img. 26: Mold for thermoforming.

Electronic Fabrication

  • ✔️ PCB design in KiCad.
  • ✔️ PCB milling.
  • ✔️ Component soldering.
  • ✔️ Continuity and operation tests.

The electronic system was designed in KiCad and fabricated by PCB milling. The board was designed to integrate the XIAO ESP32-C3 and facilitate the connection of sensors and actuators.

During assembly, connectors, resistors, and electronic components were soldered. Later, continuity and operation tests were performed.

Although some problems appeared during the first tests, the board worked correctly and allowed the monitoring and control system to be integrated.

PCB design process

Img. 27: PCB design process.

Firmware Development

  • ✔️ Sensor readings.
  • ✔️ Actuator control.
  • ✔️ LCD visualization.
  • ✔️ WiFi communication.
  • ✔️ Data sending to Firebase.

The programming was done in Arduino IDE. The firmware allows the system to:

  • Read temperature.
  • Read pH.
  • Read TDS.
  • Read light intensity.
  • Display data on the LCD screen.
  • Connect to WiFi.
  • Send data to Firebase.
  • Control lighting.
  • Control aeration.

Firebase was used as the IoT platform for real-time remote monitoring and system control.

Sensors used

Img. 28: Sensors used.

Integrated board with sensors

Img. 29: Integrated board with sensors.

Hardware and Software Integration

  • ✔️ Sensors + PCB + LCD.
  • ✔️ Lighting + relay.
  • ✔️ Aeration + relay.
  • ✔️ Firebase + remote control.

System integration was one of the most important stages. All subsystems had to work together:

  • Mechanical structure.
  • Sensors.
  • PCB.
  • LCD.
  • Lighting.
  • Aeration.
  • WiFi.
  • Firebase.

During this stage, leak tests, sensor tests, connectivity tests, and general operation tests were performed.

Firebase integration

Img. 30: Firebase integration for real-time monitoring.

Power integration

Img. 31: Power integration.

Voltage regulator integration

Img. 32: Voltage regulator integration.

Lights and pump integration

Img. 33: Integration of lights and air pump.

Heat shrink protection

Img. 34: Avoiding short circuits with heat-shrink tubing.

Integrated system

Img. 35: Integrated system; cable organization stage.

Functional Tests

  • ✔️ Leak tests.
  • ✔️ Sensor tests.
  • ✔️ Lighting tests.
  • ✔️ Aeration tests.
  • ✔️ Remote monitoring tests.

Project Timeline and Progress

Phase Start End Status
Initial researchMarchMarchCompleted
Idea definitionMarchAprilCompleted
CAD designAprilMayCompleted
Electronic designMayMayCompleted
PCB fabricationMayMayCompleted
3D printing of structureMayJuneCompleted
Acrylic thermoformingJuneJuneCompleted
Sensor integrationJuneJuneCompleted
Firebase integrationJuneJuneCompleted
Functional testsJuneJuneCompleted
Final video and slideJuneJuneCompleted
Final presentationJuneJuneCompleted

Problems Found and Solutions

Problem Cause Solution
Initial LEDs failed. The silicone coating was deteriorated. The LED strip was replaced.
Photoresistor burned. Incorrect 5V power supply. The power supply was corrected to 3.3V.
pH calibration was complicated. Lack of buffer solutions. CITE Productivo Madre de Dios provided buffer solutions.
WiFi problems. Unstable network. Mobile hotspot was used.
Irregular aeration. Inefficient initial design. The diffuser was redesigned three times.
I2C conflicts. LCD and light sensor shared the same bus. Programming and addressing were adjusted.
Failed thermoforming. Temperature and time were not optimal. Tests were repeated until the cylinder was obtained.

Final Implementation and Validation

The final version of SpiruSense was tested with the system completely integrated.

The photobioreactor was able to:

  • Display data on the LCD.
  • Send data to Firebase.
  • Remotely control lights.
  • Remotely control aeration.
  • Keep the system running without leaks.
  • Present an organized and functional structure.

Final Conclusions

SpiruSense demonstrates how digital fabrication can be applied to the development of biotechnological solutions. The project allowed me to integrate CAD design, 3D printing, thermoforming, custom electronics, programming, and IoT into a single functional system.

The development of the project showed that system integration is one of the most challenging stages, since it is not enough for each component to work separately: all components must work together inside a real physical structure.

Creative Commons License

SpiruSense by Rocío Milagros Maraví Aguilar is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License (CC BY-NC-SA 4.0).

This license allows other people to study, modify, and improve the project for educational and research purposes, as long as the original authorship is recognized, it is not used for commercial purposes without authorization, and new versions are shared under the same license.

Downloadable Project Files

Related Weekly Assignments

The development of SpiruSense was carried out progressively throughout Fab Academy. The following assignments directly contributed to the design, fabrication, programming, integration, and validation of the final project.